package com.example.j2eeapps.dao;

import com.example.j2eeapps.commons.dao.GenericDao;
import com.example.j2eeapps.domain.UserEntity;

/**
 * Data access object interface to work with user entity database operations
 * @author teo.l.c
 *
 */
public interface UserDao extends GenericDao<UserEntity, Long> {
	/**
	 * Queries database for user name availability
	 * @param userName
	 * @return true if available
	 */
	boolean checkAvailable(String userName);
	
	/**
	 * Queries user by user name
	 * @param userName
	 * @return user entity
	 */
	UserEntity loadUserByUsername(String userName);
	
	
}
